import { Bk_File_Manage } from 'src/file_manage/bk_file_manage.entity';
import { Bk_Product } from 'src/product/bk_product.entity';
import { Column, Entity, ManyToOne, PrimaryGeneratedColumn } from 'typeorm';

@Entity()
export class Bk_Product_Info {
    @PrimaryGeneratedColumn()
    id: number;

    @Column()
    product_name: string

    @Column({ select: false, nullable: true })
    product_url: string

    @Column({ type: "text", nullable: true })
    original_testPaper: string;

    @ManyToOne(() => Bk_Product, series => series.product_info)
    product: Bk_Product;

    @ManyToOne(() => Bk_File_Manage, file => file.product_info)
    video: Bk_File_Manage;
}